/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * jBeatsMain.java
 *
 * Created on Nov 11, 2012, 5:19:27 PM
 */
package cs341.cs.uwosh.edu.jBeats;
import java.awt.event.MouseEvent;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.math.*;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JFileChooser;
import org.apache.commons.io.FileUtils;
import org.apache.tika.exception.TikaException;
import org.xml.sax.SAXException;
/**
 *
 * @author haibut41
 */
public class jBeatsMain extends javax.swing.JFrame {
    Song[] songs;
    FrameCreator FC = new FrameCreator();
    int lastPLRow;
    String user;
    int lastSongRow = 0;
    String urlAsString = "/students/haibut41/NetBeansProjects/jBeats/src/cs341/cs/uwosh/edu/jBeats/resources/Test.mp3";
    SoundJLayer pauseSong = new SoundJLayer(urlAsString);
    String[] playlist;
    int curSongRow = 0;
    MouseEvent mouseEvt;
    
    public jBeatsMain(String username, Song[] songList, String[] playlistList) {
        
        
        user = username;
        playlist = playlistList;
        initComponents();
        
        songs = DatabaseInfo.getSongList(user, "master");
        populateTable(songs);
//        for(int i=0;i<Math.min(songList.length,songTable.getRowCount());i++){
//            songTable.setValueAt(songList[i],i,0);
//        }
        for(int i=0;i<playlistList.length;i++){
            playlistTable.setValueAt(playlistList[i], i+1, 0);
        }
        PlaylistComboBox.setModel(new javax.swing.DefaultComboBoxModel(DatabaseInfo.getPlaylists(user)));
    }

    private jBeatsMain() {
        initComponents();
        user = "";
    }
    
    public void populatePlaylistTable(){
        playlist = DatabaseInfo.getPlaylists(user);
        for(int i=0;i<playlist.length;i++){
            playlistTable.setValueAt(playlist[i], i+1, 0);
        }
        PlaylistComboBox.setModel(new javax.swing.DefaultComboBoxModel(DatabaseInfo.getPlaylists(user)));
    }
    
    public void populateTable(Song[] songs){
        
        Object temp[][] = new Object[songs.length][6];
        for(int i=0;i<temp.length;i++){
            temp[i][0]=songs[i].getName();
            temp[i][1]=songs[i].getAlbum();
            temp[i][2]=songs[i].getArtist();
            temp[i][3]=songs[i].getGenre();
            temp[i][4]=songs[i].getRating();
            temp[i][5]=songs[i].getAverageRating();
        }
        songTable.setModel(new javax.swing.table.DefaultTableModel(temp,new String [] {"Song", "Album", "Artist", "Genre", "Your Rating", "Average Rating"}) 
            {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Byte.class, java.lang.Byte.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false, false
            };

            @Override
            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            @Override
            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        songTable.changeSelection(lastSongRow, 0, false, false);
    }
    
    private String getLastSelectedSong(){
        return (String)songTable.getValueAt(lastSongRow, 0);
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        mainPanel = new javax.swing.JPanel();
        topPanel = new javax.swing.JPanel();
        albumArtPanel = new javax.swing.JPanel();
        staticSongLabel = new javax.swing.JLabel();
        staticArtisLabel = new javax.swing.JLabel();
        staticAlbumLabel = new javax.swing.JLabel();
        songNameLabel = new javax.swing.JLabel();
        artistNameLabel = new javax.swing.JLabel();
        albumNameLabel = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        previousButton = new javax.swing.JButton();
        nextButton = new javax.swing.JButton();
        stopButton = new javax.swing.JButton();
        playPauseButton = new javax.swing.JButton();
        PlaylistComboBox = new javax.swing.JComboBox();
        AddSongToPlaylistMainButton = new javax.swing.JButton();
        jScrollPane1 = new javax.swing.JScrollPane();
        playlistTable = new javax.swing.JTable();
        jScrollPane2 = new javax.swing.JScrollPane();
        songTable = new javax.swing.JTable();
        createUserButton = new javax.swing.JButton();
        createUserReviewButton = new javax.swing.JButton();
        createSongReviewButton = new javax.swing.JButton();
        createLoginButton = new javax.swing.JButton();
        addSongButton = new javax.swing.JButton();
        jButton1 = new javax.swing.JButton();
        jMenuBar1 = new javax.swing.JMenuBar();
        menuFile = new javax.swing.JMenu();
        quitMenuItem = new javax.swing.JMenuItem();
        menuEdit = new javax.swing.JMenu();
        editPlaylistNamesItem = new javax.swing.JMenuItem();
        DeleteSongItem = new javax.swing.JMenuItem();
        editSelectedSongButton = new javax.swing.JMenuItem();
        addSongtoPlaylist = new javax.swing.JMenuItem();
        menuAccount = new javax.swing.JMenu();
        itemUpdateProfile = new javax.swing.JMenuItem();
        createNewUserDropDown = new javax.swing.JMenuItem();
        makeAdminMenuItem = new javax.swing.JMenuItem();
        deleteUserMenuItem = new javax.swing.JMenuItem();
        itemLogout = new javax.swing.JMenuItem();
        menuUsers = new javax.swing.JMenu();
        jMenuItem1 = new javax.swing.JMenuItem();
        menuHelp = new javax.swing.JMenu();
        viewHelpItem = new javax.swing.JMenuItem();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("jBeats");
        setMinimumSize(new java.awt.Dimension(800, 600));
        setName("Form"); // NOI18N

        mainPanel.setBackground(new java.awt.Color(84, 131, 161));
        mainPanel.setMinimumSize(new java.awt.Dimension(800, 600));
        mainPanel.setName("mainPanel"); // NOI18N
        mainPanel.setPreferredSize(new java.awt.Dimension(800, 600));
        mainPanel.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseEntered(java.awt.event.MouseEvent evt) {
                mainPanelMouseEntered(evt);
            }
        });

        topPanel.setBackground(new java.awt.Color(84, 116, 191));
        topPanel.setBorder(javax.swing.BorderFactory.createEtchedBorder(new java.awt.Color(255, 153, 0), null));
        topPanel.setName("topPanel"); // NOI18N
        topPanel.setPreferredSize(new java.awt.Dimension(776, 150));

        albumArtPanel.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        albumArtPanel.setMaximumSize(new java.awt.Dimension(438, 144));
        albumArtPanel.setMinimumSize(new java.awt.Dimension(438, 144));
        albumArtPanel.setName("albumArtPanel"); // NOI18N

        staticSongLabel.setText("Song:");
        staticSongLabel.setName("staticSongLabel"); // NOI18N

        staticArtisLabel.setText("Artist:");
        staticArtisLabel.setName("staticArtisLabel"); // NOI18N

        staticAlbumLabel.setText("Album:");
        staticAlbumLabel.setName("staticAlbumLabel"); // NOI18N

        songNameLabel.setName("songNameLabel"); // NOI18N

        artistNameLabel.setName("artistNameLabel"); // NOI18N

        albumNameLabel.setName("albumNameLabel"); // NOI18N

        jLabel1.setText("Currently Playing");
        jLabel1.setName("jLabel1"); // NOI18N

        javax.swing.GroupLayout albumArtPanelLayout = new javax.swing.GroupLayout(albumArtPanel);
        albumArtPanel.setLayout(albumArtPanelLayout);
        albumArtPanelLayout.setHorizontalGroup(
            albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, albumArtPanelLayout.createSequentialGroup()
                .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(albumArtPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(staticArtisLabel)
                            .addComponent(staticSongLabel)
                            .addComponent(staticAlbumLabel))
                        .addGap(18, 18, 18)
                        .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(songNameLabel)
                            .addComponent(albumNameLabel)
                            .addComponent(artistNameLabel))
                        .addGap(91, 91, 91))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, albumArtPanelLayout.createSequentialGroup()
                        .addContainerGap(190, Short.MAX_VALUE)
                        .addComponent(jLabel1)
                        .addGap(31, 31, 31)))
                .addGap(128, 128, 128))
        );
        albumArtPanelLayout.setVerticalGroup(
            albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(albumArtPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel1)
                .addGap(5, 5, 5)
                .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(staticSongLabel)
                    .addComponent(songNameLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 15, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(staticArtisLabel)
                    .addComponent(artistNameLabel))
                .addGap(18, 18, 18)
                .addGroup(albumArtPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(staticAlbumLabel)
                    .addComponent(albumNameLabel))
                .addGap(20, 20, 20))
        );

        previousButton.setText("<<");
        previousButton.setName("previousButton"); // NOI18N
        previousButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                previousButtonActionPerformed(evt);
            }
        });

        nextButton.setText(">>");
        nextButton.setName("nextButton"); // NOI18N
        nextButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                nextButtonActionPerformed(evt);
            }
        });

        stopButton.setText("Stop");
        stopButton.setName("stopButton"); // NOI18N
        stopButton.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                stopButtonClicked(evt);
            }
        });

        playPauseButton.setText("Play");
        playPauseButton.setName("playPauseButton"); // NOI18N
        playPauseButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                playPauseActionPerformed(evt);
            }
        });

        PlaylistComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        PlaylistComboBox.setName("PlaylistComboBox"); // NOI18N

        AddSongToPlaylistMainButton.setText("Add Song to Playlist");
        AddSongToPlaylistMainButton.setName("AddSongToPlaylistMainButton"); // NOI18N
        AddSongToPlaylistMainButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                AddSongToPlaylistMainButtonActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout topPanelLayout = new javax.swing.GroupLayout(topPanel);
        topPanel.setLayout(topPanelLayout);
        topPanelLayout.setHorizontalGroup(
            topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(topPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(topPanelLayout.createSequentialGroup()
                        .addComponent(previousButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(playPauseButton)
                        .addGap(2, 2, 2)
                        .addComponent(stopButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(nextButton))
                    .addComponent(AddSongToPlaylistMainButton)
                    .addComponent(PlaylistComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 101, Short.MAX_VALUE)
                .addComponent(albumArtPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 435, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );
        topPanelLayout.setVerticalGroup(
            topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(topPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(topPanelLayout.createSequentialGroup()
                        .addComponent(albumArtPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 139, Short.MAX_VALUE)
                        .addContainerGap())
                    .addGroup(topPanelLayout.createSequentialGroup()
                        .addGroup(topPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(previousButton)
                            .addComponent(stopButton)
                            .addComponent(nextButton)
                            .addComponent(playPauseButton))
                        .addGap(18, 18, 18)
                        .addComponent(AddSongToPlaylistMainButton)
                        .addGap(18, 18, 18)
                        .addComponent(PlaylistComboBox, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(39, 39, 39))))
        );

        jScrollPane1.setName("jScrollPane1"); // NOI18N

        playlistTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {"Master"},
                {"test1"},
                {"test2"},
                {"test33"}
            },
            new String [] {
                "Playlist Table"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }
        });
        playlistTable.setName("playlistTable"); // NOI18N
        playlistTable.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        playlistTable.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                playlistTableMouseClicked(evt);
            }
        });
        jScrollPane1.setViewportView(playlistTable);
        playlistTable.getColumnModel().getColumn(0).setResizable(false);

        jScrollPane2.setName("jScrollPane2"); // NOI18N

        songTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {"Song1", "1", "Album", "Arist", new Byte((byte) 1), new Byte((byte) 1)},
                {"Song2", "2", "Album", "Arist", new Byte((byte) 1), new Byte((byte) 1)},
                {"Song3", "3", "Album", "Arist", new Byte((byte) 2), new Byte((byte) 1)},
                {"Song4", "4", "Album", "Arist", new Byte((byte) 2), new Byte((byte) 2)},
                {"Song5", "5", "Album", "Arist", new Byte((byte) 3), new Byte((byte) 2)},
                {"Song6", "6", "Album2", "Arist", new Byte((byte) 3), new Byte((byte) 2)},
                {"Song7", "7", "Album2", "Arist", new Byte((byte) 4), new Byte((byte) 3)},
                {"Song8", "8", "Album2", "Arist", new Byte((byte) 4), new Byte((byte) 3)},
                {"Song9", "9", "Album2", "Arist", new Byte((byte) 5), new Byte((byte) 3)},
                {"Song10", "10", "Album2", "Arist", new Byte((byte) 5), new Byte((byte) 4)},
                {"Song11", "11", "Album3", "Arist2", new Byte((byte) 1), new Byte((byte) 4)},
                {"Song12", "12", "Album3", "Arist2", new Byte((byte) 1), new Byte((byte) 4)},
                {"Song13", "13", "Album3", "Arist2", new Byte((byte) 2), new Byte((byte) 5)},
                {"Song14", "14", "Album3", "Arist2", new Byte((byte) 2), new Byte((byte) 5)},
                {"Song15", "15", "Album3", "Arist2", new Byte((byte) 3), new Byte((byte) 5)},
                {"Song16", "16", "Album4", "Arist2", new Byte((byte) 3), new Byte((byte) 1)},
                {"Song17", "17", "Album4", "Arist2", new Byte((byte) 4), new Byte((byte) 1)},
                {"Song18", "18", "Album4", "Arist2", new Byte((byte) 4), new Byte((byte) 1)},
                {"Song19", "19", "Album4", "Arist2", new Byte((byte) 5), new Byte((byte) 2)},
                {"Song20", "20", "Album4", "Arist2", new Byte((byte) 5), new Byte((byte) 2)},
                {"Song21", "21", "Album5", "Arist3", new Byte((byte) 1), new Byte((byte) 2)},
                {"Song22", "22", "Album5", "Arist3", new Byte((byte) 1), new Byte((byte) 3)},
                {"Song23", "23", "Album5", "Arist3", new Byte((byte) 2), new Byte((byte) 3)},
                {"Song24", "24", "Album5", "Arist3", new Byte((byte) 2), new Byte((byte) 3)},
                {"Song25", "25", "Album5", "Arist3", new Byte((byte) 3), new Byte((byte) 4)},
                {"Song26", "26", "Album6", "Arist3", new Byte((byte) 3), new Byte((byte) 4)},
                {"Song27", "27", "Album6", "Arist3", new Byte((byte) 4), new Byte((byte) 4)},
                {"Song28", "28", "Album6", "Arist3", new Byte((byte) 4), new Byte((byte) 5)},
                {"Song29", "29", "Album6", "Arist3", new Byte((byte) 5), new Byte((byte) 5)},
                {"Song30", "30", "Album6", "Arist3", new Byte((byte) 5), new Byte((byte) 5)},
                {"Song31", "31", "Album7", "Arist4", new Byte((byte) 1), new Byte((byte) 1)},
                {"Song32", "32", "Album7", "Arist4", new Byte((byte) 1), new Byte((byte) 1)},
                {"Song33", "33", "Album7", "Arist4", new Byte((byte) 2), new Byte((byte) 1)},
                {"Song34", "34", "Album7", "Arist4", new Byte((byte) 2), new Byte((byte) 2)},
                {"Song35", "35", "Album7", "Arist4", new Byte((byte) 3), new Byte((byte) 2)},
                {"Song36", "36", "Album8", "Arist4", new Byte((byte) 3), new Byte((byte) 2)},
                {"Song37", "37", "Album8", "Arist4", new Byte((byte) 4), new Byte((byte) 3)},
                {"Song38", "38", "Album8", "Arist4", new Byte((byte) 4), new Byte((byte) 3)},
                {"Song39", "39", "Album8", "Arist4", new Byte((byte) 5), new Byte((byte) 3)},
                {"Song40", "40", "Album8", "Arist4", new Byte((byte) 5), new Byte((byte) 4)},
                {"Song41", "41", "Album9", "Arist5", new Byte((byte) 1), new Byte((byte) 4)},
                {"Song42", "42", "Album9", "Arist5", new Byte((byte) 1), new Byte((byte) 4)},
                {"Song43", "43", "Album9", "Arist5", new Byte((byte) 2), new Byte((byte) 5)},
                {"Song44", "44", "Album9", "Arist5", new Byte((byte) 2), new Byte((byte) 5)},
                {"Song45", "45", "Album9", "Arist5", new Byte((byte) 3), new Byte((byte) 5)},
                {"Song46", "46", "Album10", "Arist5", new Byte((byte) 3), new Byte((byte) 1)},
                {"Song47", "47", "Album10", "Arist5", new Byte((byte) 4), new Byte((byte) 1)},
                {"Song48", "48", "Album10", "Arist5", new Byte((byte) 4), new Byte((byte) 1)},
                {"Song49", "49", "Album10", "Arist5", new Byte((byte) 5), new Byte((byte) 2)},
                {"Song50", "50", "Album10", "Arist5", new Byte((byte) 5), new Byte((byte) 2)}
            },
            new String [] {
                "Song", "Length", "Album", "Artist", "Your Rating", "Total Rating"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Byte.class, java.lang.Byte.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        songTable.setName("songTable"); // NOI18N
        songTable.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        songTable.getTableHeader().setReorderingAllowed(false);
        songTable.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                songTableMouseClicked(evt);
            }
        });
        jScrollPane2.setViewportView(songTable);
        songTable.getColumnModel().getSelectionModel().setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        songTable.getColumnModel().getColumn(1).setHeaderValue("Length");

        createUserButton.setText("User Profile");
        createUserButton.setName("createUserButton"); // NOI18N
        createUserButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                createUserButtonActionPerformed(evt);
            }
        });

        createUserReviewButton.setText("User Reviews");
        createUserReviewButton.setName("createUserReviewButton"); // NOI18N
        createUserReviewButton.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                userReviewButtonClicked(evt);
            }
        });

        createSongReviewButton.setText("Song Reviews");
        createSongReviewButton.setName("createSongReviewButton"); // NOI18N
        createSongReviewButton.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                songReviewButtonClicked(evt);
            }
        });

        createLoginButton.setText("Logout");
        createLoginButton.setName("createLoginButton"); // NOI18N
        createLoginButton.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                logoutButtonClicked(evt);
            }
        });

        addSongButton.setText("Import Song");
        addSongButton.setName("addSongButton"); // NOI18N
        addSongButton.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                addSongButtonMouseClicked(evt);
            }
        });

        jButton1.setText("Edit Song Info");
        jButton1.setName("jButton1"); // NOI18N
        jButton1.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                jButton1MouseClicked(evt);
            }
        });

        javax.swing.GroupLayout mainPanelLayout = new javax.swing.GroupLayout(mainPanel);
        mainPanel.setLayout(mainPanelLayout);
        mainPanelLayout.setHorizontalGroup(
            mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(mainPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(mainPanelLayout.createSequentialGroup()
                        .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE)
                            .addComponent(addSongButton, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE)
                            .addComponent(createLoginButton)
                            .addComponent(createUserButton, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE)
                            .addComponent(createUserReviewButton, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE)
                            .addComponent(createSongReviewButton, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE)
                            .addComponent(jButton1, javax.swing.GroupLayout.DEFAULT_SIZE, 160, Short.MAX_VALUE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 614, Short.MAX_VALUE))
                    .addComponent(topPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 780, Short.MAX_VALUE))
                .addContainerGap())
        );
        mainPanelLayout.setVerticalGroup(
            mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(mainPanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(topPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 165, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(26, 26, 26)
                .addGroup(mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(mainPanelLayout.createSequentialGroup()
                        .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 95, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(createUserButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(createUserReviewButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(createSongReviewButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(addSongButton)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jButton1)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 120, Short.MAX_VALUE)
                        .addComponent(createLoginButton))
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 408, Short.MAX_VALUE))
                .addContainerGap())
        );

        jMenuBar1.setName("jMenuBar1"); // NOI18N

        menuFile.setText("File");
        menuFile.setName("menuFile"); // NOI18N

        quitMenuItem.setText("Quit");
        quitMenuItem.setName("quitMenuItem"); // NOI18N
        quitMenuItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                quitMenuItemActionPerformed(evt);
            }
        });
        menuFile.add(quitMenuItem);

        jMenuBar1.add(menuFile);

        menuEdit.setText("Edit");
        menuEdit.setName("menuEdit"); // NOI18N

        editPlaylistNamesItem.setText("Edit Playlist Names");
        editPlaylistNamesItem.setName("editPlaylistNamesItem"); // NOI18N
        editPlaylistNamesItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editPlaylistNamesItemActionPerformed(evt);
            }
        });
        menuEdit.add(editPlaylistNamesItem);

        DeleteSongItem.setText("Delete Selected Song");
        DeleteSongItem.setName("DeleteSongItem"); // NOI18N
        DeleteSongItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                DeleteSongItemActionPerformed(evt);
            }
        });
        menuEdit.add(DeleteSongItem);

        editSelectedSongButton.setText("Edit Selected Song");
        editSelectedSongButton.setName("editSelectedSongButton"); // NOI18N
        editSelectedSongButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editSelectedSongButtonActionPerformed(evt);
            }
        });
        menuEdit.add(editSelectedSongButton);

        addSongtoPlaylist.setText("Add Selected Song to Playlist");
        addSongtoPlaylist.setName("addSongtoPlaylist"); // NOI18N
        addSongtoPlaylist.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                addSongtoPlaylistActionPerformed(evt);
            }
        });
        menuEdit.add(addSongtoPlaylist);

        jMenuBar1.add(menuEdit);

        menuAccount.setText("Account");
        menuAccount.setName("menuAccount"); // NOI18N

        itemUpdateProfile.setText("View/Update Profile");
        itemUpdateProfile.setName("itemUpdateProfile"); // NOI18N
        itemUpdateProfile.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                itemUpdateProfileActionPerformed(evt);
            }
        });
        menuAccount.add(itemUpdateProfile);
        try{
          if(DatabaseInfo.isAdmin(user)){
            createNewUserDropDown.setText("Create User...");
            createNewUserDropDown.setName("createNewUserDropDown"); // NOI18N
            createNewUserDropDown.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    createNewUserDropDownActionPerformed(evt);
                }
            });
            menuAccount.add(createNewUserDropDown);

            makeAdminMenuItem.setText("Make Admin");
            makeAdminMenuItem.setName("makeAdminMenuItem"); // NOI18N
            makeAdminMenuItem.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    makeAdminMenuItemActionPerformed(evt);
                }
            });
            menuAccount.add(makeAdminMenuItem);

            deleteUserMenuItem.setText("Delete User");
            deleteUserMenuItem.setName("deleteUserMenuItem"); // NOI18N
            deleteUserMenuItem.addActionListener(new java.awt.event.ActionListener() {
                public void actionPerformed(java.awt.event.ActionEvent evt) {
                    deleteUserMenuItemActionPerformed(evt);
                }
            });
            menuAccount.add(deleteUserMenuItem);
          }
        } catch (Exception e){
            
        }

        itemLogout.setText("Logout");
        itemLogout.setName("itemLogout"); // NOI18N
        itemLogout.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                itemLogoutActionPerformed(evt);
            }
        });
        menuAccount.add(itemLogout);

        jMenuBar1.add(menuAccount);

        menuUsers.setText("Reviews");
        menuUsers.setName("menuUsers"); // NOI18N

        jMenuItem1.setText("Add Review");
        jMenuItem1.setName("jMenuItem1"); // NOI18N
        jMenuItem1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jMenuItem1ActionPerformed(evt);
            }
        });
        menuUsers.add(jMenuItem1);

        jMenuBar1.add(menuUsers);

        menuHelp.setText("Help");
        menuHelp.setName("menuHelp"); // NOI18N

        viewHelpItem.setText("View Help");
        viewHelpItem.setName("viewHelpItem"); // NOI18N
        viewHelpItem.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                viewHelpActionPerformed(evt);
            }
        });
        menuHelp.add(viewHelpItem);

        jMenuBar1.add(menuHelp);

        setJMenuBar(jMenuBar1);

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(mainPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(mainPanel, javax.swing.GroupLayout.DEFAULT_SIZE, 621, Short.MAX_VALUE)
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

private void stopButtonClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_stopButtonClicked
    playPauseButton.setText("Play");
    if (!pauseSong.isStopped)
        pauseSong.stop();
}//GEN-LAST:event_stopButtonClicked

private void userReviewButtonClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_userReviewButtonClicked
    jBeatsUserReviews frame = FC.createUserReviews(user);
    frame.setVisible(true);
}//GEN-LAST:event_userReviewButtonClicked

private void songReviewButtonClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_songReviewButtonClicked
    jBeatsSongReviews frame = FC.createSongReviews(songs[lastSongRow]);
    frame.setVisible(true);
}//GEN-LAST:event_songReviewButtonClicked

private void logoutButtonClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_logoutButtonClicked
    jBeatsLogin frame = FC.createLogin();
    frame.setVisible(true);
    pauseSong.stop();
    this.dispose();
}//GEN-LAST:event_logoutButtonClicked

private void createUserButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_createUserButtonActionPerformed
    jBeatsUser frame = FC.createUser(user, playlist);
    frame.setVisible(true);
}//GEN-LAST:event_createUserButtonActionPerformed

private void songTableMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_songTableMouseClicked
    mouseEvt = evt;
    lastSongRow = songTable.getSelectedRow();
    if(lastSongRow == curSongRow){
        if(pauseSong.isPlaying && !playPauseButton.getText().equals("Pause"))
            playPauseButton.setText("Pause");
    } else { //lastSongRow != curSongRow
        if(pauseSong.isPlaying && !playPauseButton.getText().equals("Play"))
            playPauseButton.setText("Play");
    }
}//GEN-LAST:event_songTableMouseClicked

private void addSongButtonMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_addSongButtonMouseClicked
        JFileChooser fc = new JFileChooser();
        fc.showOpenDialog(this);
        File source = fc.getSelectedFile();
        if (source.getName().contains(".mp3")){
            String path = "src/cs341/cs/uwosh/edu/jBeats/Songs/"+source.getName();
            File target = new File(path);
            System.out.println(path);
            try {
                FileUtils.copyFile(source, target);
            } catch (IOException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            }
            DatabaseInfo dbi = new DatabaseInfo();
            try {
                //String path = path.replaceAll("\\" , "/");
                dbi.addSong(path);
            } catch (FileNotFoundException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            } catch (IOException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            } catch (SAXException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            } catch (TikaException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
}//GEN-LAST:event_addSongButtonMouseClicked

private void jButton1MouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jButton1MouseClicked
    jBeatsEditSongInfo frame = FC.createEditSongInfo(user, songs[lastSongRow]);
    frame.setVisible(true);
}//GEN-LAST:event_jButton1MouseClicked

private void itemLogoutActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_itemLogoutActionPerformed
    jBeatsLogin j = new jBeatsLogin();
    j.setVisible(true);
    pauseSong.stop();
    this.dispose();
}//GEN-LAST:event_itemLogoutActionPerformed

private void mainPanelMouseEntered(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_mainPanelMouseEntered
    populateTable(songs);
}//GEN-LAST:event_mainPanelMouseEntered

private void playlistTableMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_playlistTableMouseClicked
    lastPLRow = playlistTable.getSelectedRow();
    songs = DatabaseInfo.getSongList(user, (String)playlistTable.getValueAt(lastPLRow, 0));
    //System.out.println((String)playlistTable.getValueAt(lastPLRow, 0));
    populateTable(songs);
}//GEN-LAST:event_playlistTableMouseClicked

private void DeleteSongItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_DeleteSongItemActionPerformed
    if(  ((String)playlistTable.getValueAt(lastPLRow, 0)).equals("Master")  ){
            try {
                if (DatabaseInfo.isAdmin(user)){
                    DatabaseInfo.deleteSong(songs[lastSongRow].getSongID());
                } else {
                    System.out.println("No permission to Delete Songs from master playlist");
                }
            } catch (SQLException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            }
    } else {
            try {
                DatabaseInfo.deletePlaylistSong(user, (String)playlistTable.getValueAt(lastPLRow, 0), songs[lastSongRow].getSongID());
            } catch (SQLException ex) {
                Logger.getLogger(jBeatsMain.class.getName()).log(Level.SEVERE, null, ex);
            }
    }
    songs = DatabaseInfo.getSongList(user, (String)playlistTable.getValueAt(lastPLRow, 0));
    populateTable(songs);
}//GEN-LAST:event_DeleteSongItemActionPerformed

private void jMenuItem1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jMenuItem1ActionPerformed
    AddReview frame = FC.createAddReview(user, songs[lastSongRow]);
    frame.setVisible(true);
}//GEN-LAST:event_jMenuItem1ActionPerformed

private void createNewUserDropDownActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_createNewUserDropDownActionPerformed
    jBeatsAddUser frame = FC.createAddUser();
    frame.setVisible(true);
}//GEN-LAST:event_createNewUserDropDownActionPerformed

private void itemUpdateProfileActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_itemUpdateProfileActionPerformed
    jBeatsUser frame = FC.createUser(user, playlist);
    frame.setVisible(true);
}//GEN-LAST:event_itemUpdateProfileActionPerformed

private void deleteUserMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_deleteUserMenuItemActionPerformed
    jBeatsDeleteUser frame = FC.createDeleteUser(user);
    frame.setVisible(true);
}//GEN-LAST:event_deleteUserMenuItemActionPerformed

private void editSelectedSongButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editSelectedSongButtonActionPerformed
    jBeatsEditSongInfo frame = FC.createEditSongInfo(user, songs[lastSongRow]);
    frame.setVisible(true);
}//GEN-LAST:event_editSelectedSongButtonActionPerformed

private void editPlaylistNamesItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editPlaylistNamesItemActionPerformed
    jBeatsEditPlaylistName frame = FC.createjBeatsEditPlaylistName(user, this);
    frame.setVisible(true);
}//GEN-LAST:event_editPlaylistNamesItemActionPerformed

private void makeAdminMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_makeAdminMenuItemActionPerformed
    jBeatsMakeAdmin frame = FC.createjBeatsMakeAdmin(user);
    frame.setVisible(true);
}//GEN-LAST:event_makeAdminMenuItemActionPerformed

private void quitMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_quitMenuItemActionPerformed
    this.dispose();
}//GEN-LAST:event_quitMenuItemActionPerformed

private void playPauseActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_playPauseActionPerformed
    
    urlAsString = songs[lastSongRow].getFilePath();
    songNameLabel.setText((String)songTable.getValueAt(lastSongRow, 0));
    artistNameLabel.setText((String)songTable.getValueAt(lastSongRow, 2));
    albumNameLabel.setText((String)songTable.getValueAt(lastSongRow, 1));
    
    if(lastSongRow==curSongRow){
        if(playPauseButton.getText().equals("Play")){//if paused
            playPauseButton.setText("Pause");

            if(pauseSong.isStopped){
                    pauseSong = new SoundJLayer(urlAsString);
                    pauseSong.play();
                    curSongRow = songTable.getSelectedRow();

             }else{
               pauseSong.play();
            }

        } else{ //if playing
            playPauseButton.setText("Play");
            pauseSong.pauseToggle();
        }
    } else{ //lastSongRow != curSongRow
        pauseSong.stop();
        playPauseButton.setText("Pause");
        pauseSong = new SoundJLayer(urlAsString);
        pauseSong.play();
        curSongRow = songTable.getSelectedRow(); 
    }
}//GEN-LAST:event_playPauseActionPerformed

private void previousButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_previousButtonActionPerformed
    if (songTable.getSelectedRow()==0){
		songTable.changeSelection(songTable.getRowCount()-1, songTable.getSelectedColumn(), false, false);
	    songTableMouseClicked(mouseEvt);
	    playPauseActionPerformed(evt);
    }else {
    	songTable.changeSelection(songTable.getSelectedRow()-1, songTable.getSelectedColumn(), false, false);
	    songTableMouseClicked(mouseEvt);
	    playPauseActionPerformed(evt);
    }
}//GEN-LAST:event_previousButtonActionPerformed

private void nextButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_nextButtonActionPerformed
	if (songTable.getSelectedRow()==songTable.getRowCount()-1){
	    songTable.changeSelection(0, songTable.getSelectedColumn(), false, false);
	    songTableMouseClicked(mouseEvt);
	    playPauseActionPerformed(evt);
	} else {
		songTable.changeSelection(songTable.getSelectedRow()+1, songTable.getSelectedColumn(), false, false);
	    songTableMouseClicked(mouseEvt);
	    playPauseActionPerformed(evt);
	}
}//GEN-LAST:event_nextButtonActionPerformed

private void addSongtoPlaylistActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_addSongtoPlaylistActionPerformed

    jBeatsAddSongtoPlaylist frame = FC.createjBeatsAddSongToPlaylist(songs[lastSongRow].getSongID(), songs[lastSongRow].getName(), user);
    frame.setVisible(true);
}//GEN-LAST:event_addSongtoPlaylistActionPerformed

private void viewHelpActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_viewHelpActionPerformed
    jBeatsHelp frame = FC.createHelp();
    frame.setVisible(true);
}//GEN-LAST:event_viewHelpActionPerformed

private void AddSongToPlaylistMainButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_AddSongToPlaylistMainButtonActionPerformed
   DatabaseInfo.addPlaylistSong(user, (String)PlaylistComboBox.getSelectedItem(), songs[lastSongRow].getSongID());
   songs = DatabaseInfo.getSongList(user, (String)playlistTable.getValueAt(lastPLRow, 0));
   populateTable(songs);   
}//GEN-LAST:event_AddSongToPlaylistMainButtonActionPerformed
                              

    /**
     * @param args the command line arguments
     */
//    public static void main(String args[]) {
//        /* Set the Nimbus look and feel */
//        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
//        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
//         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
//         */
//        try {
//            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
//                if ("Nimbus".equals(info.getName())) {
//                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
//                    break;
//                }
//            }
//        } catch (ClassNotFoundException ex) {
//            java.util.logging.Logger.getLogger(jBeatsMain.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (InstantiationException ex) {
//            java.util.logging.Logger.getLogger(jBeatsMain.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (IllegalAccessException ex) {
//            java.util.logging.Logger.getLogger(jBeatsMain.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
//            java.util.logging.Logger.getLogger(jBeatsMain.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        }
//        //</editor-fold>
//
//        /* Create and display the form */
//        java.awt.EventQueue.invokeLater(new Runnable() {
//
//            public void run() {
//                new jBeatsMain().setVisible(true);
//            }
//        });
//    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton AddSongToPlaylistMainButton;
    private javax.swing.JMenuItem DeleteSongItem;
    private javax.swing.JComboBox PlaylistComboBox;
    private javax.swing.JButton addSongButton;
    private javax.swing.JMenuItem addSongtoPlaylist;
    private javax.swing.JPanel albumArtPanel;
    private javax.swing.JLabel albumNameLabel;
    private javax.swing.JLabel artistNameLabel;
    private javax.swing.JButton createLoginButton;
    private javax.swing.JMenuItem createNewUserDropDown;
    private javax.swing.JButton createSongReviewButton;
    private javax.swing.JButton createUserButton;
    private javax.swing.JButton createUserReviewButton;
    private javax.swing.JMenuItem deleteUserMenuItem;
    private javax.swing.JMenuItem editPlaylistNamesItem;
    private javax.swing.JMenuItem editSelectedSongButton;
    private javax.swing.JMenuItem itemLogout;
    private javax.swing.JMenuItem itemUpdateProfile;
    private javax.swing.JButton jButton1;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JMenuBar jMenuBar1;
    private javax.swing.JMenuItem jMenuItem1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JPanel mainPanel;
    private javax.swing.JMenuItem makeAdminMenuItem;
    private javax.swing.JMenu menuAccount;
    private javax.swing.JMenu menuEdit;
    private javax.swing.JMenu menuFile;
    private javax.swing.JMenu menuHelp;
    private javax.swing.JMenu menuUsers;
    private javax.swing.JButton nextButton;
    private javax.swing.JButton playPauseButton;
    private javax.swing.JTable playlistTable;
    private javax.swing.JButton previousButton;
    private javax.swing.JMenuItem quitMenuItem;
    private javax.swing.JLabel songNameLabel;
    private javax.swing.JTable songTable;
    private javax.swing.JLabel staticAlbumLabel;
    private javax.swing.JLabel staticArtisLabel;
    private javax.swing.JLabel staticSongLabel;
    private javax.swing.JButton stopButton;
    private javax.swing.JPanel topPanel;
    private javax.swing.JMenuItem viewHelpItem;
    // End of variables declaration//GEN-END:variables
}
